package cn.swenty.backstage.framework.database.mapper;

import java.util.List;
import java.util.Map;

import cn.swenty.backstage.framework.common.FormMap;
import cn.swenty.backstage.framework.database.entity.Entity;

/**
 * 已经实现民基本的 增,删,改,查接口,不需要重复写
 * 所有mapper都继承这个BaseMapper
 * @author lanyuan
 * @date 2015-4-26
 * @Email: mmm333zzz520@163.com
 * @version 3.0v
 */
public interface BasicMapper {
	
	/**
	 * @param t
	 * @return
	 */
	public <T extends Entity> int $delete(T t);
	
	public <T extends Entity> int $update (T t);
	
	
	public <T extends Entity> int $updateFull (T t);
	
	public <T extends Entity> int $save (T t);
	
	public <T extends Entity> List<T> $query (T t);
	
	public List<FormMap> initTableField(Map<String,String> t);
	
}
